$(function(){
    $("#filter select").change(function(){
        var url = $("#filter").data('filter-url');
		url += "&project=" + $("#filter_project").val();
		url += "&creator=" + $("#filter_creator").val();
		url += "&worker=" + ($("#filter_worker").val() === undefined ? 0 : $("#filter_worker").val());
		url += "&taskType=" + $("#filter_task_type").val();
		
		$.post($.nette.href = url, $.nette.success);

        $.nette.spinner.css({
                position: 'absolute',
                left: '50%',
                top: '50%'
        });
    });
});
